package com.shixi.shixitraining.shixitraining.ui.tabapply.fragment;

import android.support.design.widget.TabLayout;
import android.support.v4.view.ViewPager;

import com.shixi.shixitraining.shixitraining.R;
import com.shixi.shixitraining.shixitraining.base.TabhostBaseFragment;
import com.shixi.shixitraining.shixitraining.ui.tabmine.adapter.MyApplyPagerAdapter;

/**
 * Created by shenyan on 2018/7/5.
 */

public class ApplyFragment extends TabhostBaseFragment {
    @Override
    protected int getlayoutId() {
        return R.layout.fragment_apply;
    }

    @Override
    protected void initPager() {
        TabLayout mTab = (TabLayout) mContentView.findViewById(R.id.tab_apply);
        ViewPager mViewPager = (ViewPager) mContentView.findViewById(R.id.viewpager_apply);
        mTab.setTabMode(TabLayout.MODE_FIXED);
        mTab.setupWithViewPager(mViewPager);


        MyApplyPagerAdapter adapter = new MyApplyPagerAdapter(getChildFragmentManager());
        mViewPager.setAdapter(adapter);

    }



}
